package com.ruoyi.project.travel.domain;

import com.ruoyi.framework.aspectj.lang.annotation.Excel;
import com.ruoyi.framework.web.domain.MbEntity;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import org.springframework.format.annotation.DateTimeFormat;
import lombok.Data;
import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;

/**
 * 用户 对象 tr_user
 *
 * @author HYD
 * @date 2020-06-14
 */

@Data
@TableName("tr_user")
@ApiModel(value="tr_user对象", description="用户 ")
public class User extends MbEntity {

    @TableId(value = "id", type = IdType.AUTO)
    @ApiModelProperty(value = "主键")
    private Long id;

    @Excel(name = "用户名")
    @TableField("user_name")
    @ApiModelProperty(value = "用户名")
    private String userName;

    @Excel(name = "头像")
    @TableField("user_face")
    @ApiModelProperty(value = "头像")
    private String userFace;

    @Excel(name = "电话号码")
    @TableField("mobile")
    @ApiModelProperty(value = "电话号码")
    private String mobile;

    @Excel(name = "用户唯一标识")
    @TableField("unionid")
    @ApiModelProperty(value = "用户唯一标识")
    private String unionid;

    @Excel(name = "用户openid")
    @TableField("openid")
    @ApiModelProperty(value = "用户openid")
    private String openid;

    @Excel(name = "微信号")
    @TableField("wechat_id")
    @ApiModelProperty(value = "微信号")
    private String wechatId;

    @Excel(name = "是否会员 0：不是会员，1：是会员")
    @TableField("vip")
    @ApiModelProperty(value = "是否会员 0：不是会员，1：是会员")
    private String vip;

    @Excel(name = "注册时间", width = 30, dateFormat = "yyyy-MM-dd")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss") //格式化前台日期入参注解
    @TableField("reg_time")
    @ApiModelProperty(value = "注册时间")
    private Date regTime;

    public String getUserName() {
        return userName;
    }

    public void setUserName(String userName) {
        this.userName = userName;
    }

    public String getUserFace() {
        return userFace;
    }

    public void setUserFace(String userFace) {
        this.userFace = userFace;
    }

    public String getMobile() {
        return mobile;
    }

    public void setMobile(String mobile) {
        this.mobile = mobile;
    }

    public String getUnionid() {
        return unionid;
    }

    public void setUnionid(String unionid) {
        this.unionid = unionid;
    }

    public String getOpenid() {
        return openid;
    }

    public void setOpenid(String openid) {
        this.openid = openid;
    }

    public String getWechatId() {
        return wechatId;
    }

    public void setWechatId(String wechatId) {
        this.wechatId = wechatId;
    }

    public String getVip() {
        return vip;
    }

    public void setVip(String vip) {
        this.vip = vip;
    }

    public Date getRegTime() {
        return regTime;
    }

    public void setRegTime(Date regTime) {
        this.regTime = regTime;
    }

    @Override
    public String toString() {
        return "User{" +
                "id=" + id +
                ", userName='" + userName + '\'' +
                ", userFace='" + userFace + '\'' +
                ", mobile='" + mobile + '\'' +
                ", unionid='" + unionid + '\'' +
                ", openid='" + openid + '\'' +
                ", wechatId='" + wechatId + '\'' +
                ", vip='" + vip + '\'' +
                ", regTime=" + regTime +
                '}';
    }
}
